import { useTokenStore } from '@/stores/token.js'
import request from '@/utils/request.js'//导入request.js请求工具
//文章分类列表查询
export const academicListService = ()=>{
    // const tokenStore = useTokenStore();
    //在pinia中定义的响应式数据，都不需要.value可以直接使用
    // return request.get('/category',{headers:{'Authorization':tokenStore.token}})
    return request.get('/academic/selectlist')
}

//学生添加接口 参数是json
export const academicAddService = (academicData)=>{
    return request.post('/academic/add',academicData)
}

//学生修改 参数是json
export const academicUpdateService=(academicData)=>{
    return request.put('/academic/updateac',academicData)
}


//学生删除
export const academicDeleteService=(studentId)=>{
    return request.delete(`/academic/delete/${studentId}`)
}